import { $get, $put } from '@js/request'
import { CaseSchema } from '@src/components/schema/caseSchema'

// 获取案件详情
export async function getCaseDetailRequest (id: string): Promise<CaseSchema> {
  const res = await $get(`/api/commission/case/${id}`)
  return res.data
}

// 更新案件数据
export async function updateCaseDetailRequest (id: string, data: { [k: string]: any }): Promise<void> {
  const res = await $put(`/api/commission/case/${id}`, data)
  return res.data
}
